home *** CD-ROM | disk | FTP | other *** search
AMOS Source Code | 1978-10-10 | 790 b | 28 lines |
- Rem ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- Rem Joystick control under AMAL
- Rem
- Rem Due to a few early requests
- Rem asking how this was possible
- Rem Aaron decided to give you the
- Rem neccessary code to get going.
- Rem
- Rem ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- Load "AMOS_DATA:Magic_Forest/Mfsprites.Abk"
- Curs Off : Flash Off : Hide
- Get Sprite Palette
- A$="Let R0=1 ; " : Rem R0 is the speed factor
- A$=A$+"A: If J1&1 then Jump E ;" : Rem up
- A$=A$+"B: If J1&2 then Jump F ;" : Rem down
- A$=A$+"C: If J1&4 then Jump G ;" : Rem left
- A$=A$+"D: If J1&8 then Jump H ;" : Rem right
- A$=A$+"Jump A ;"
- A$=A$+"G: Let X=X-R0 ; Jump D ;"
- A$=A$+"H: Let X=X+R0 ; Jump A ;"
- A$=A$+"E: Let Y=Y-R0 ; Jump B ;"
- A$=A$+"F: Let Y=Y+R0 ; Jump C ;"
- Bob 1,160,100,41
- Channel 1 To Bob 1
- Amal 1,A$
- Amal On
- Do
- Loop